File Manager

While Carbon supports most of the File Manager interface, there are a number of significant changes.

You should not access File Manager structures directly if accessor functions for the structure exist. For example, you should call PBGetFCBInfo rather than calling LMGetFCBSPtr and walking the FCB table.

Similarly, you should create file system specification (FSSpec) records using the functions PBMakeFSSpec or FSMakeFSSpec instead of filling in your own structures. File system specification records must contain a volume reference number, a parent directory, and a name. Substituting a working directory for the volume reference number or a full or partial pathname for the name is not supported.

File Manager functions that support MFS (the Macintosh file system) are not supported in Carbon. These include

* functions, such as OpenWD and GetWDInfo, that manipulate working directories

* functions that identify a file or folder using a volume reference number and pathname but not a parent directory ID. You should use the HFS version of these calls (which use a parent directory ID) instead.

Functions that cannot be called by PowerPC applications (such as PBGetAltAccessSync and PBGetAltAccessAsync) are not supported.

You should use only documented File Manager interfaces in your application. For example, you should use a documented API call to get low memory information rather than access undocumented low memory global variables or vectors directly.

The default volume format for Carbon is the Mac OS Extended format; in most cases you will not need to modify your application to gain this volume support.

Carbon does not support the File System Manager (FSM) functions defined in the header file FSM.h. FSM plug-ins today often must make assumptions about File Manager data structures that may not be valid in Carbon. In addition, some plug-ins use 68K calling conventions when calling internal File Manager functions. Since the File System Manager was designed for a single-threaded file system, it cannot use the full threading capabilities of Mac OS X.